package com.github.itdachen.entity;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 代码生成业务表字段
 *
 * @author 王大宸
 * @date 2023-09-23 21:25:55
 */
public class DevTableColumn implements Serializable {
    private static final long serialVersionUID = 1L;


    /**
     * 编号
     */
    private String id;

    /**
     * 归属表编号
     */
    private String tableId;

    /**
     * 列名称
     */
    private String columnName;

    /**
     * 列描述
     */
    private String columnComment;

    /**
     * 列类型
     */
    private String columnType;

    /**
     * JAVA类型
     */
    private String javaType;

    /**
     * JAVA类型名称
     */
    private String javaTypeTitle = "String";

    /**
     * JAVA字段名
     */
    private String javaField;

    /**
     * 前端TS类型
     */
    private String tsType;

    /**
     * 是否主键（1是）
     */
    private String isPk;

    /**
     * 是否使用（1是）
     */
    private String isUsable;

    /**
     * 是否 DTO 类字段（1是）
     */
    private String isDto;

    /**
     * 是否 VO 类字段（1是）
     */
    private String isVo;

    /**
     * 是否必填（1是）
     */
    private String isRequired;

    /**
     * 是否为表单字段（1是）
     */
    private String isForm;

    /**
     * 是否列表字段（1是）
     */
    private String isList;

    /**
     * 是否导出字段（1是）
     */
    private String isExp;

    /**
     * 是否查询字段（1是）
     */
    private String isQuery;

    /**
     * 查询方式（等于、不等于、大于、小于、范围）
     */
    private String queryType;

    /**
     * 查询类型名称
     */
    private String queryTitle = "=";

    /**
     * 显示类型（文本框、文本域、下拉框、复选框、单选框、日期控件）
     */
    private String htmlType;

    /**
     * HTML显示类型名称
     */
    private String htmlTitle = "文本框";

    /**
     * 字典类型
     */
    private String dictType = "VALID_FLAG";

    /**
     * 字典类型名称
     */
    private String dictTitle = "有效标志";

    /**
     * 排序
     */
    private Integer sort;

    /**
     * 创建时间
     */
    private LocalDateTime createTime;

    /**
     * 创建人
     */
    private String createUser;

    /**
     * 创建人ID
     */
    private String createUserId;

    /**
     * 更新时间
     */
    private LocalDateTime updateTime;

    /**
     * 更新人
     */
    private String updateUser;

    /**
     * 更新人ID
     */
    private String updateUserId;


    public void setId(String id) {
        this.id = id;
    }

    public String getId() {
        return id;
    }

    public void setTableId(String tableId) {
        this.tableId = tableId;
    }

    public String getTableId() {
        return tableId;
    }

    public void setColumnName(String columnName) {
        this.columnName = columnName;
    }

    public String getColumnName() {
        return columnName;
    }

    public void setColumnComment(String columnComment) {
        this.columnComment = columnComment;
    }

    public String getColumnComment() {
        return columnComment;
    }

    public void setColumnType(String columnType) {
        this.columnType = columnType;
    }

    public String getColumnType() {
        return columnType;
    }

    public void setJavaType(String javaType) {
        this.javaType = javaType;
    }

    public String getJavaType() {
        return javaType;
    }

    public void setJavaTypeTitle(String javaTypeTitle) {
        this.javaTypeTitle = javaTypeTitle;
    }

    public String getJavaTypeTitle() {
        return javaTypeTitle;
    }

    public void setJavaField(String javaField) {
        this.javaField = javaField;
    }

    public String getJavaField() {
        return javaField;
    }

    public void setTsType(String tsType) {
        this.tsType = tsType;
    }

    public String getTsType() {
        return tsType;
    }

    public void setIsPk(String isPk) {
        this.isPk = isPk;
    }

    public String getIsPk() {
        return isPk;
    }

    public void setIsUsable(String isUsable) {
        this.isUsable = isUsable;
    }

    public String getIsUsable() {
        return isUsable;
    }

    public void setIsDto(String isDto) {
        this.isDto = isDto;
    }

    public String getIsDto() {
        return isDto;
    }

    public void setIsVo(String isVo) {
        this.isVo = isVo;
    }

    public String getIsVo() {
        return isVo;
    }

    public void setIsRequired(String isRequired) {
        this.isRequired = isRequired;
    }

    public String getIsRequired() {
        return isRequired;
    }

    public void setIsForm(String isForm) {
        this.isForm = isForm;
    }

    public String getIsForm() {
        return isForm;
    }

    public void setIsList(String isList) {
        this.isList = isList;
    }

    public String getIsList() {
        return isList;
    }

    public void setIsExp(String isExp) {
        this.isExp = isExp;
    }

    public String getIsExp() {
        return isExp;
    }

    public void setIsQuery(String isQuery) {
        this.isQuery = isQuery;
    }

    public String getIsQuery() {
        return isQuery;
    }

    public void setQueryType(String queryType) {
        this.queryType = queryType;
    }

    public String getQueryType() {
        return queryType;
    }

    public void setQueryTitle(String queryTitle) {
        this.queryTitle = queryTitle;
    }

    public String getQueryTitle() {
        return queryTitle;
    }

    public void setHtmlType(String htmlType) {
        this.htmlType = htmlType;
    }

    public String getHtmlType() {
        return htmlType;
    }

    public void setHtmlTitle(String htmlTitle) {
        this.htmlTitle = htmlTitle;
    }

    public String getHtmlTitle() {
        return htmlTitle;
    }

    public void setDictType(String dictType) {
        this.dictType = dictType;
    }

    public String getDictType() {
        return dictType;
    }

    public void setDictTitle(String dictTitle) {
        this.dictTitle = dictTitle;
    }

    public String getDictTitle() {
        return dictTitle;
    }

    public void setSort(Integer sort) {
        this.sort = sort;
    }

    public Integer getSort() {
        return sort;
    }

    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }

    public LocalDateTime getCreateTime() {
        return createTime;
    }

    public void setCreateUser(String createUser) {
        this.createUser = createUser;
    }

    public String getCreateUser() {
        return createUser;
    }

    public void setCreateUserId(String createUserId) {
        this.createUserId = createUserId;
    }

    public String getCreateUserId() {
        return createUserId;
    }

    public void setUpdateTime(LocalDateTime updateTime) {
        this.updateTime = updateTime;
    }

    public LocalDateTime getUpdateTime() {
        return updateTime;
    }

    public void setUpdateUser(String updateUser) {
        this.updateUser = updateUser;
    }

    public String getUpdateUser() {
        return updateUser;
    }

    public void setUpdateUserId(String updateUserId) {
        this.updateUserId = updateUserId;
    }

    public String getUpdateUserId() {
        return updateUserId;
    }


    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("tableId", getTableId())
                .append("columnName", getColumnName())
                .append("columnComment", getColumnComment())
                .append("columnType", getColumnType())
                .append("javaType", getJavaType())
                .append("javaTypeTitle", getJavaTypeTitle())
                .append("javaField", getJavaField())
                .append("tsType", getTsType())
                .append("isPk", getIsPk())
                .append("isUsable", getIsUsable())
                .append("isDto", getIsDto())
                .append("isVo", getIsVo())
                .append("isRequired", getIsRequired())
                .append("isForm", getIsForm())
                .append("isList", getIsList())
                .append("isExp", getIsExp())
                .append("isQuery", getIsQuery())
                .append("queryType", getQueryType())
                .append("queryTitle", getQueryTitle())
                .append("htmlType", getHtmlType())
                .append("htmlTitle", getHtmlTitle())
                .append("dictType", getDictType())
                .append("dictTitle", getDictTitle())
                .append("sort", getSort())
                .append("createTime", getCreateTime())
                .append("createUser", getCreateUser())
                .append("createUserId", getCreateUserId())
                .append("updateTime", getUpdateTime())
                .append("updateUser", getUpdateUser())
                .append("updateUserId", getUpdateUserId())
                .toString();
    }


}
